Repository navigation
web: mark the shared shell of the 20 ungated pages for translation (#3479) - #3480
Conversation
…3479) Add data-ui-* markers to the skip link, rail, account menu and help menu on the 19 sidebar pages and about, and regenerate docs/inventory/visible-controls.json with scripts/visible_inventory.py (230 records gain attributes, no line shifts). The markers are inert: pages.js still gates locale rendering to /chat and /settings, so no page's text, wording or lang attribute changes. Related #3479
Lead review — head
|
What
Marks the shared shell chrome on the 20 pages that are still outside the locale gate, so that a later page-family slice can translate the rail, account menu and help menu by opening the gate instead of editing each page's markup.
Related #3479. Refs #3438.Scope
agents,artifacts,automations,contacts,discover,download,guide,help,home,meetings,members,memory,onboarding,privacy,profile,skills,team-runs,team,terms) +about.data-ui-*markers: 19 per sidebar page, 3 onabout(which has noapp-rail, so it gets onlyshell.skip,settings.back,shell.settings). Skip link, railaria-label, rail itemtitle/aria-label/text, appearance toggle, account menu, help menu, sign out.docs/inventory/visible-controls.jsonregenerated withscripts/visible_inventory.py: 230 records gain the new attributes in theirdatafield, no line shifts.register, is out of scope: it does not use the shared shell (own chrome, noapp-rail), so there is nothing on it to mark.Deliberately not in this slice: no
pages.jschange, no page added to a locale allowlist, no import ofshell/system-locale.mjson these pages, andchat/settingsuntouched (already gated by #3438 / #3478).Why markers and not the gate
Opening the gate now would serve these pages with
lang="en"andcontent-language: enwhile 17–349 lines of Chinese body copy per page remain — a WCAG 3.1.1 mislabelling. Markers are inert until a page's own copy lands, so this slice cannot mislabel anything.Byte equality
Adding attributes changes bytes, so "response byte-identical to
1f2cf1b7" cannot hold by construction. Equivalent check, for 23 pages × 2 languages (zh-CN,en), rendered through the shipped handler: the HTML is identical once everydata-ui-*attribute and every marker-only<span>wrapper is removed, andstatuspluscontent-languageare equal everywhere. Zero differences. Text,title/aria-labelwording andlangare unchanged on both languages.Effect, measured with the gate temporarily opened in a scratch copy (not part of this patch)
Shell-block CJK lines across the 20 pages: 362 → 1; CJK characters in shell text nodes: 2; CJK attribute values: 0. The single residual line is
discover/index.html's own#login-panellink inside the rail — page slice scope, not shared chrome.Tests (local, not CI)
node --test --test-concurrency=2 tests/*.test.mjs: 974/974 pass, exit 0.tests.test_visible_inventory2 OK,tests.test_settings_page21 OK,tests.test_shell_page5 OK,tests.test_skills_page4 OK,tests.test_docs_pages3 OK,tests.test_agents_page12 OK.Known delta
38
data-ui-titlemarkers (2 per sidebar page) reference catalog keys whose Chinese phrasing differs from the page's current wording (shell.appearance.hint,shell.issue.hint). They are left untouched here to keep this slice byte-neutral;/settingsaligned the same two strings in #3478, so the page slices should pick one wording on purpose.Related #3479